package com.ly.heart.domain;

import java.util.Date;
import java.util.List;

import com.baomidou.mybatisplus.annotation.IdType;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.ly.common.core.domain.BaseEntity;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ly.common.annotation.Excel;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

/**
 * 勘测申请对象 erp_survey_apply_info
 * @author wutao
 * @date 2024-05-22
 */
@TableName ("erp_survey_apply_info")
@ApiModel (value = "erp_survey_apply_info对象", description = "勘测申请")
@Data
public class SurveyApplyEntity extends BaseEntity {

    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    @TableId (value = "id", type = IdType.INPUT)
    private String id;

    /**
     * 客户Id
     */
    @ApiModelProperty ("客户Id")
    @TableField ("customer_id")
    @Excel (name = "客户Id")
    private String customerId;

    /**
     * 勘测数据采集Id，关联勘测数据采集表
     */
    @ApiModelProperty ("勘测数据采集Id，关联勘测数据采集表")
    @TableField ("survey_base_data_id")
    @Excel (name = "勘测数据采集Id，关联勘测数据采集表")
    private String surveyBaseDataId;

    /**
     * 客户联系人，文本输入，防止变更
     */
    @ApiModelProperty ("客户联系人，文本输入，防止变更")
    @TableField ("customer_name")
    @Excel (name = "客户联系人，文本输入，防止变更")
    private String customerName;

    /**
     * 客户联系方式，文本
     */
    @ApiModelProperty ("客户联系方式，文本")
    @TableField ("customer_tel")
    @Excel (name = "客户联系方式，文本")
    private String customerTel;

    /**
     * 地址
     */
    @ApiModelProperty ("地址")
    @TableField ("address")
    @Excel (name = "地址")
    private String address;

    /**
     * 申请人Id，选择框选择
     */
    @ApiModelProperty ("业务员Id")
    @TableField ("business_user_id")
    @Excel (name = "业务员")
    private String businessUserId;

    /**
     * 申请人Id，选择框选择
     */
    @ApiModelProperty ("申请人Id，选择框选择")
    @TableField ("apply_id")
    @Excel (name = "申请人Id，选择框选择")
    private String applyId;

    /**
     * 申请时间
     */
    @ApiModelProperty ("申请时间")
    @TableField ("apply_time")
    @JsonFormat (pattern = "yyyy-MM-dd")
    @Excel (name = "申请时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date applyTime;

    /**
     * 是否航拍;1:是;2:否
     */
    @ApiModelProperty ("是否航拍;1:是;2:否")
    @TableField ("is_photograph")
    @Excel (name = "是否航拍;1:是;2:否")
    private Integer isPhotograph;

    /**
     * 彩钢瓦房是否有爬梯;1:是;2:否
     */
    @ApiModelProperty ("彩钢瓦房是否有爬梯;1:是;2:否")
    @TableField ("is_stairs")
    @Excel (name = "彩钢瓦房是否有爬梯;1:是;2:否")
    private Integer isStairs;

    /**
     * 爬梯是否具备攀爬条件;1:是;2:否
     */
    @ApiModelProperty ("爬梯是否具备攀爬条件;1:是;2:否")
    @TableField ("is_stairs_qualified")
    @Excel (name = "爬梯是否具备攀爬条件;1:是;2:否")
    private Integer isStairsQualified;

    /**
     * 查勘装备是否齐全;1:是;2:否
     */
    @ApiModelProperty ("查勘装备是否齐全;1:是;2:否")
    @TableField ("is_complete")
    @Excel (name = "查勘装备是否齐全;1:是;2:否")
    private Integer isComplete;

    /**
     * 梁/柱/檩条是否测量;1:是;2:否
     */
    @ApiModelProperty ("梁/柱/檩条是否测量;1:是;2:否")
    @TableField ("is_measure")
    @Excel (name = "梁/柱/檩条是否测量;1:是;2:否")
    private Integer isMeasure;

    /**
     * 配电房能否进入;1:能;2:否
     */
    @ApiModelProperty ("配电房能否进入;1:能;2:否")
    @TableField ("is_dis_room_in")
    @Excel (name = "配电房能否进入;1:能;2:否")
    private Integer isDisRoomIn;

    /**
     * 是否具有测量条件;1:是;2:否
     */
    @ApiModelProperty ("是否具有测量条件;1:是;2:否")
    @TableField ("is_measure_qualified")
    @Excel (name = "是否具有测量条件;1:是;2:否")
    private Integer isMeasureQualified;

    /**
     * 是否具有测量条件;1:是;2:否
     */
    @ApiModelProperty ("是否拥有不动产权证；1：有；2：无")
    @TableField ("is_certificate")
    @Excel (name = "是否拥有不动产权证；1：有；2：无")
    private Integer isCertificate;

    /**
     * 是否具有测量条件;1:是;2:否
     */
    @ApiModelProperty ("是否拥有变压器产权；1：有；2：无")
    @TableField ("is_transformer")
    @Excel (name = "是否拥有变压器产权；1：有；2：无")
    private Integer isTransformer;

    /**
     * 预计完成时间
     */
    @ApiModelProperty ("预计完成时间")
    @TableField ("plan_complete_time")
    @JsonFormat (pattern = "yyyy-MM-dd")
    @Excel (name = "预计完成时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date planCompleteTime;


    /**
     * 申请人Id，登录用户Id
     */
    @ApiModelProperty ("勘查执行人Id")
    @TableField ("execute_user_id")
    @Excel (name = "勘查执行人Id")
    private String executeUserId;

    /**
     * 申请人Id，登录用户Id
     */
    @ApiModelProperty ("申请人Id，登录用户Id")
    @TableField ("user_id")
    @Excel (name = "申请人Id，登录用户Id")
    private String userId;

    /**
     * 备注
     */
    @ApiModelProperty ("备注")
    @TableField ("remarks")
    @Excel (name = "备注")
    private String remarks;

    /**
     * 更新时间
     */
    @ApiModelProperty ("创建时间")
    @TableField ("create_time")
    @JsonFormat (pattern = "yyyy-MM-dd")
    @Excel (name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date createTime;

    /**
     * 更新时间
     */
    @ApiModelProperty ("更新时间")
    @TableField ("change_time")
    @JsonFormat (pattern = "yyyy-MM-dd")
    @Excel (name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date changeTime;

    /**
     * $column.columnComment
     */
    @ApiModelProperty ("更新时间")
    @TableField ("is_used")
    @Excel (name = "更新时间")
    private Integer isUsed;


    @TableField (exist = false)
    private List<FileEntity> fileEntities;

    @Override
    public String toString () {
        return new ToStringBuilder ( this, ToStringStyle.MULTI_LINE_STYLE )
                .append ( "id", getId () )
                .append ( "customerId", getCustomerId () )
                .append ( "customerName", getCustomerName () )
                .append ( "customerTel", getCustomerTel () )
                .append ( "applyId", getApplyId () )
                .append ( "applyTime", getApplyTime () )
                .append ( "isPhotograph", getIsPhotograph () )
                .append ( "isStairs", getIsStairs () )
                .append ( "isStairsQualified", getIsStairsQualified () )
                .append ( "isComplete", getIsComplete () )
                .append ( "isMeasure", getIsMeasure () )
                .append ( "isDisRoomIn", getIsDisRoomIn () )
                .append ( "isMeasureQualified", getIsMeasureQualified () )
                .append ( "planCompleteTime", getPlanCompleteTime () )
                .append ( "userId", getUserId () )
                .append ( "remarks", getRemarks () )
                .append ( "createTime", getCreateTime () )
                .append ( "changeTime", getChangeTime () )
                .append ( "isUsed", getIsUsed () )
                .toString ();
    }
}
